package com.frxuexi.myvideo.adapter

import androidx.databinding.DataBindingUtil
import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.frxuexi.lib_base.entity.CommentBeanItem
import com.frxuexi.lib_base.entity.MyVideoCommentBeanItem
import com.frxuexi.myvideo.R
import com.frxuexi.myvideo.databinding.ItemMycommentBinding

class MyVideoCommentAdapter:BaseQuickAdapter<MyVideoCommentBeanItem,BaseViewHolder>(R.layout.item_mycomment) {

    override fun onItemViewHolderCreated(viewHolder: BaseViewHolder, viewType: Int) {
        super.onItemViewHolderCreated(viewHolder, viewType)
        DataBindingUtil.bind<ItemMycommentBinding>(viewHolder.itemView)
    }
    override fun convert(helper: BaseViewHolder, item: MyVideoCommentBeanItem) {
        val binding = DataBindingUtil.getBinding<ItemMycommentBinding>(helper.itemView)!!
        binding.bean=item
    }
}